package managers;

import java.sql.SQLException;
import java.util.List;

import stores.TipusStore;
import stores.TipusStoreImpl;
import workspace.Workspace;
import beans.Tipus;

public class TipusManagerImpl implements TipusManager {

	private TipusStore tipusStore = new TipusStoreImpl();

	@Override
	public List<Tipus> loadTipusLista(Workspace workspace) throws SQLException {
		return tipusStore.loadTipusLista(workspace);
	}

	@Override
	public Tipus insertTipus(Workspace workspace, Tipus newTipus)
			throws SQLException {
		return tipusStore.insertTipus(workspace, newTipus);
	}

	@Override
	public Tipus updateTipus(Workspace workspace, Tipus updatedTipus)
			throws SQLException {
		return tipusStore.updateTipus(workspace, updatedTipus);
	}

	@Override
	public boolean deleteTipus(Workspace workspace, long userId)
			throws SQLException {
		return tipusStore.deleteTipus(workspace, userId);
	}

	@Override
	public boolean deleteTipusForTest(Workspace workspace, long userId)
			throws SQLException {
		return tipusStore.deleteTipusForTest(workspace, userId);
	}

}
